<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
	<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
	<meta name="language" content="en" />

	<link rel="stylesheet" type="text/css" href="<?php echo bu(); ?>/css/ui/jqueryui.css" media="screen, projection" />
	<link rel="stylesheet" type="text/css" href="<?php echo bu(); ?>/css/styles.css?v=1" media="screen, projection" />
	<!--[if lt IE 8]>
	<link rel="stylesheet" type="text/css" href="<?php echo bu(); ?>/css/styles_ie.css" media="screen, projection" />
	<![endif]-->
	<?php Yii::app()->clientScript->registerCoreScript('jquery'); ?>
	<?php Yii::app()->clientScript->registerCoreScript('jquery.ui'); ?>
	<?php Yii::app()->clientScript->registerScriptFile(bu() .'/js/tooltip.min.js'); ?>
	<?php Yii::app()->clientScript->registerScriptFile(bu() .'/js/jquery.appear-1.1.1.js'); ?>
	<?php Yii::app()->clientScript->registerScriptFile(bu() .'/js/core2.js'); ?>
	<?php Yii::app()->clientScript->registerScriptFile(bu() .'/js/core.js'); ?>
	<?php Yii::app()->clientScript->registerScriptFile(bu() .'/js/picker.js'); ?>
	<?php Yii::app()->clientScript->registerScriptFile(bu() .'/js/calendar.js'); ?>
	<?php Yii::app()->clientScript->registerScriptFile(bu() .'/js/ajax.js'); ?>

	<title><?php echo CHtml::encode($this->pageTitle); ?></title>
	<script type="text/javascript">
		//<![CDATA[
		var lang = {
			error_no_items_selected: 'No items selected! At least one checkbox must be ticked off to perform this action.',
			delete_confirmation: '<?php echo t('Are you sure to delete this item?') ?>',
			save: 'Save',
			close: 'Close',
			loading: 'Processing...',
			notice: 'Warning',
			warning: 'Notice',
			error: 'Error',
			error_ajax: 'Error',
			text_are_you_sure_to_proceed: 'Are you sure ?',
			text_page_loading: 'Processing...'
		};
		var changes_warning = 'N';
		var images_dir = '<?php echo bu('/images') ?>';
		var translate_mode = false;
		var notice_displaying_time = 10;
		var currencies = {
			'primary': {
				'decimals_separator': ',',
				'thousands_separator': '.',
				'decimals': '0'
			}
		};
		$(document).ready(function(){
			jQuery.runCart('A');
		});
		//]]>
	</script>
</head>

<body>

	<?php if ( !user()->isGuest ) : ?>
	<div id="header">
 

		<div id="top_quick_links">
			

			<div class="nowrap">
				<?php echo l(t('Site Front'), param('frontUrl'), array('class' => 'top-quick-links', 'target' => '_blank')) ?>&nbsp;&nbsp;|&nbsp;
				<a href="{$index_script}?dispatch=profiles.update&amp;user_id={$auth.user_id}"><strong class="lowercase"></strong></a>
				<?php echo l('<strong class="lowercase">'.user()->name.'</strong>', '#', array('encode' => false)); ?>
				(<?php echo l(t('Sign Out'), array('/site/logout')) ?>)
			</div>
		</div>
		
		<?php $this->renderPartial('//common/navigation') ?>

	<!--header-->
	</div>

	<?php endif; ?>

	<table cellpadding="0" cellspacing="0" border="0" width="100%">
		<tr valign="top">
			<td class="<?php if ( user()->isGuest ) : ?>login-page<?php else : ?>content<?php endif; ?>">

				<div id="main_column<?php if ( user()->isGuest ) : ?>_login<?php endif; ?>" class="clear">
					<?php echo $content; ?>
				</div>
			</td>
		</tr>
	</table>
	<div class="clear"></div>

	<div class="cm-notification-container"></div>
</body>
</html>
